<!--
*Author：
 *Contact：
 *代码由框架生成,任何更改都可能导致被代码生成器覆盖
 *业务请在@/extension/system/workbusiness/V_AssignMents.js此处编写
 -->
<template>
    <view-grid ref="grid"
               :columns="columns"
               :detail="detail"
               :editFormFields="editFormFields"
               :editFormOptions="editFormOptions"
               :searchFormFields="searchFormFields"
               :searchFormOptions="searchFormOptions"
               :table="table"
               :extend="extend">
    </view-grid>
</template>
<script>
    import extend from "@/extension/system/workbusiness/V_AssignMents.js";
    import { ref, defineComponent } from "vue";
    export default defineComponent({
        setup() {
            const table = ref({
                key: 'PROJTask_Id',
                footer: "Foots",
                cnName: '钳工任务分配',
                name: 'workbusiness/V_AssignMents',
                url: "/V_AssignMents/",
                sortName: "CreateOn"
            });
            const editFormFields = ref({"StartDate":"","DeadlineDate":"","WorkerName":""});
            const editFormOptions = ref([[{"title":"开始日期","field":"StartDate","type":"date"},
                               {"title":"截止日期","field":"DeadlineDate","type":"date"},
                               {"dataKey":"钳工","data":[],"title":"钳工","field":"WorkerName","type":"select"}]]);
            const searchFormFields = ref({});
            const searchFormOptions = ref([]);
            const columns = ref([{field:'PROJTask_Id',title:'PROJTask_Id',type:'guid',width:110,hidden:true,require:true,align:'left'},
                       {field:'ProjectCode',title:'ProjectCode',type:'string',width:110,hidden:true,align:'left'},
                       {field:'TaskAssignee',title:'TaskAssignee',type:'string',width:110,hidden:true,align:'left'},
                       {field:'TaskTitle',title:'任务名称',type:'string',link:true,width:110,align:'left',sort:true},
                       {field:'StartDate',title:'开始日期',type:'datetime',width:150,align:'left',sort:true},
                       {field:'DeadlineDate',title:'截止日期',type:'datetime',width:150,align:'left',sort:true},
                       {field:'Description',title:'Description',type:'string',width:220,align:'left'},
                       {field:'Status',title:'状态',type:'string',width:110,align:'left'},
                       {field:'CreateBy',title:'CreateBy',type:'string',width:110,hidden:true,align:'left'},
                       {field:'CreateOn',title:'CreateOn',type:'datetime',width:150,hidden:true,align:'left',sort:true},
                       {field:'UpdateBy',title:'UpdateBy',type:'string',width:110,hidden:true,align:'left'},
                       {field:'LastUpdateOn',title:'LastUpdateOn',type:'datetime',width:150,hidden:true,align:'left',sort:true},
                       {field:'IsDeleted',title:'IsDeleted',type:'bool',width:110,hidden:true,align:'left'},
                       {field:'WorkerName',title:'钳工',type:'string',bind:{ key:'钳工',data:[]},width:120,align:'left'},
                       {field:'TaskProgress',title:'进度',type:'decimal',width:110,align:'left'}]);
            const detail = ref({
                cnName: "#detailCnName",
                table: "#detailTable",
                columns: [],
                sortName: "",
                key: ""
            });
            return {
                table,
                extend,
                editFormFields,
                editFormOptions,
                searchFormFields,
                searchFormOptions,
                columns,
                detail,
            };
        },
    });
</script>
